module namespace mainview = "http://www.xmlproject.com/smi/lib/view/mainview";

import module namespace utilities = "http://www.xmlproject.com/smi/lib/utilities";
import module namespace http ="http://www.28msec.com/modules/http";


(:~
 : Renders the main start page with the search form  
 :
 : @return returns a complete HTML page with head and body
 :)
 
declare function mainview:show()
{

<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html" charset="utf-8" />
        <meta name="description" content="" />
        <meta name="keywords" content="" />
        <title>Movie Search</title>
        <link href="/css/style.css" rel="stylesheet" type="text/css" />
    </head>
<body>
    <div id="wrap">
        <div id="header" align="left">
        </div>
        
        <div id="menu">
            <a href="index.xq" class="selected">Home Page</a>
            <a href="aboutus.xq" class="selected">About us</a>
        </div>
        
        <div id="body">
          <div id="top" align="center">
                <h1>Movie Search</h1>
                <form id="search-form" action="/moviesearch/search" method="GET">
                        <p>
                            <input type="text" size="60" name="query" value="" />
                            {utilities:generate-dates()}
                            <input type="submit" value="Movie Search" />
                        </p>
            </form>       
                <hr/>
            </div>
            <div id="content"><img src="/images/startImage.png" width="625" height="352" alt="image" />
                <br clear="both" />
          </div>
            <div id="footer"> Project of XML and Databases :: Master in Applied Computer Science, University of Freiburg 2012 </div>
        </div>
        
        <div id="bottom">
        </div>
    </div>
</body>
</html>
};
